package a.j;

import a.c.bb;
import a.c.d;
import a.c.e;
import a.c.m;
import a.d.w;

public class wf
  extends gf
{
  protected jd m;
  private we G;
  private boolean H;
  public static int I;
  
  public wf()
  {
    this(null);
  }
  
  public wf(df paramdf)
  {
    super(paramdf);
  }
  
  protected boolean a(d paramd)
  {
    return qf.a(paramd, k());
  }
  
  public void mousePressedLeft(double paramDouble1, double paramDouble2)
  {
    boolean bool = ld.E;
    this.H = false;
    jd localjd = f(paramDouble1, paramDouble2);
    if (!bool) {
      if (localjd == null)
      {
        g();
        if (!bool) {
          if (!ld.D) {
            return;
          }
        }
      }
      else
      {
        a(true);
        this.G = new we();
        this.m = localjd;
      }
    }
    a(localjd);
  }
  
  public void mouseDraggedLeft(double paramDouble1, double paramDouble2)
  {
    boolean bool = ld.E;
    if ((bool) || (this.m != null))
    {
      if (!bool) {
        if (!this.H)
        {
          this.H = true;
          localObject = k();
          ((g)localObject).z();
          if (bool) {
            break label139;
          }
          e locale = c(this.m);
          if ((locale != null) && (locale.g() == localObject))
          {
            this.G.c((g)localObject, locale);
            this.G.a((g)localObject, locale);
            ((g)localObject).a(this.m.c());
            this.G.a(this.i, new bb(locale).l(), this.m.c());
          }
        }
      }
      label139:
      Object localObject = d(paramDouble1, paramDouble2);
      e(((w)localObject).a(), ((w)localObject).b());
      this.i.b();
    }
  }
  
  public void mouseReleasedLeft(double paramDouble1, double paramDouble2)
  {
    c(paramDouble1, paramDouble2);
  }
  
  private void c(double paramDouble1, double paramDouble2)
  {
    boolean bool = ld.E;
    if (!bool) {
      if (this.m != null)
      {
        w localw = d(paramDouble1, paramDouble2);
        e(localw.a(), localw.b());
        a(this.m, localw.a(), localw.b());
        this.i.b();
        this.m = null;
      }
    }
    if (!bool)
    {
      if (this.H) {
        k().A();
      }
      this.H = false;
      this.i.e(0);
      this.G.a();
      this.G = null;
      if (bool) {}
    }
    else if (a())
    {
      a(false);
    }
    g();
  }
  
  public void b()
    throws UnsupportedOperationException
  {
    c(a(this.s.getX()), b(this.s.getY()));
  }
  
  protected void a(jd paramjd) {}
  
  protected void a(jd paramjd, double paramDouble1, double paramDouble2) {}
  
  protected w d(double paramDouble1, double paramDouble2)
  {
    return b(this.m, paramDouble1, paramDouble2);
  }
  
  protected w b(jd paramjd, double paramDouble1, double paramDouble2)
  {
    de localde = paramjd.g().a();
    ee localee = localde.a(paramjd.b(), new w(paramDouble1, paramDouble2));
    return localde.a(paramjd, localee);
  }
  
  protected void e(double paramDouble1, double paramDouble2)
  {
    c(this.m, paramDouble1, paramDouble2);
  }
  
  protected void c(jd paramjd, double paramDouble1, double paramDouble2)
  {
    d(paramjd, paramDouble1, paramDouble2);
    this.G.a(k());
  }
  
  private void d(jd paramjd, double paramDouble1, double paramDouble2)
  {
    boolean bool2 = ld.E;
    boolean bool1 = ld.D;
    de localde = paramjd.g().a();
    ee localee = localde.a(paramjd.b(), new w(paramDouble1, paramDouble2));
    paramjd.a(localee);
    g localg = k();
    e locale = c(paramjd);
    m localm = paramjd.c();
    do
    {
      if (!localm.e()) {
        break;
      }
      d locald = localm.a();
      if (!bool2)
      {
        if (a(locald))
        {
          tb localtb = localg.t(locald);
          if (!bool2) {
            if (locald.e() == locale) {
              ud.a(this.i, localtb, paramDouble1, paramDouble2, true);
            }
          }
          if (locald.f() == locale) {
            ud.a(this.i, localtb, paramDouble1, paramDouble2, false);
          }
        }
        localm.f();
      }
    } while (!bool1);
  }
  
  private jd f(double paramDouble1, double paramDouble2)
  {
    return a(paramDouble1, paramDouble2).s();
  }
  
  protected sc a(double paramDouble1, double paramDouble2)
  {
    sc localsc = a(paramDouble1, paramDouble2, 6, true);
    a(localsc);
    return localsc;
  }
  
  private static e c(jd paramjd)
  {
    ld localld = paramjd.b();
    if (!ld.E) {}
    return localld == null ? null : localld.n();
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.j.wf

 * JD-Core Version:    0.7.0.1

 */